home *** CD-ROM | disk | FTP | other *** search
/ CyberMycha 2003 May / cmycha200305.iso / MutantStorm / setup_mutantstorm_demo.exe / {app} / script / player_missile_1.lua < prev    next >
Text File  |  2002-10-01  |  2KB  |  75 lines

  1.  
  2. -- leave me
  3.     local actor = ACTOR_preload()
  4. -- leave me
  5.  
  6.     actor[cp_actor_name]            = "player_missile_1"
  7.     actor[cp_model_dir]                = "player"
  8.     actor[cp_model_name]            = "missile1"
  9.  
  10.     actor[cp_actor_type]            = cat_bullet + cat_player + cat_beastie
  11.  
  12.     actor[cp_hit_power]                = 30.0
  13.     actor[cp_launch_scale_min]        = 50.0
  14.     actor[cp_player_bullet_rate]    = 0.1
  15.  
  16.     actor[cp_move_target]            = "nearest_beastie"
  17.     actor[cp_in_beastie_count]        = 0
  18.  
  19.     actor[cp_move_type]                    = cmt_track
  20.     actor[cp_i_collide_with_beasties]    = cat_beastie + cat_fence
  21.  
  22.     actor[cp_fence_bounce_percent]        = -1.0
  23.  
  24.     -- movement
  25.     actor[cp_move_speed_min]        = 1.0
  26.     actor[cp_move_speed_max]        = 1.0
  27.     actor[cp_move_acceleration]        = 100.0
  28.     actor[cp_move_deceleration]        = 10.0
  29.     actor[cp_move_inertia_accn]        = 0.0
  30.     actor[cp_move_inertia_decn]        = 0.0
  31.  
  32.     actor[cp_weight]                = 1.0
  33.  
  34.      actor[cp_difficulty_adjust_speed] = 0.0
  35. --    actor[cp_spin_speed_min]        = 15.0
  36. --    actor[cp_spin_speed_max]        = 15.0
  37.  
  38. -- leave me
  39.     c_preload_model( actor )
  40. -- leave me
  41.  
  42.     c_set_random_anim( "pulse", 50.0, 100.0, 0.0, 0.0 )
  43.     c_set_random_anim( "spin", 100.0, 100.0, 0.0, 0.0 )
  44.     c_add_particle_to_anim( "spin", "exaust", "player-missile" )
  45.  
  46.     c_set_use_explosion_for( "bye_bye", "missile-flash", exp_no_align, 0.0, 0.0, 2000.0, 2000.0, {0.0} )
  47.     c_add_particle_to_explosion( "missile-flash", "explode", "", "missile-exp" )
  48.     c_add_sound_to_explosion( "missile-flash", "explode", "boom-exp" )
  49.     c_add_sound_to_anim( "keyset1", "player-misslaunch" )
  50.     
  51.     -- default for this beastie
  52.  
  53.     -- new state
  54.     -- set new stuff
  55.     actor[cp_move_speed_min]        = 1.0
  56.     actor[cp_move_speed_max]        = 1.0
  57.     actor[cp_move_acceleration]        = 0.1
  58.     actor[cp_move_deceleration]        = 20.0
  59.     actor[cp_move_inertia_accn]        = 0.95
  60.     actor[cp_move_inertia_decn]        = 0.95
  61.  
  62.     actor[cp_turn_speed_still]            = 80.0
  63.     actor[cp_turn_acceleration_still]    = 80.0
  64.     actor[cp_turn_inertia_still]        = 0.1
  65.     actor[cp_turn_speed_moving]        = 4.0
  66.     actor[cp_turn_acceleration_moving]    = 4.0
  67.     actor[cp_turn_inertia_moving]        = 0.1
  68.     -- send out
  69.     c_set_trigger_state( "my_time_alive", 0.15, 0.15, actor )
  70.     -- new state
  71.  
  72.     -- new state
  73.     c_set_trigger_mutate( "byebye", "my_time_alive", 5.0, 6.0, 1.0, 1.0, 1.0, 1.0 )
  74.     -- new state
  75.